Skip to content

Landing: Pharos engraving hero; snapshot revert hardening#9

Merged
Aayam Bansal (aayambansal) merged 3 commits into
mainfrom
landing-pharos-hero
Jul 4, 2026
Merged

Landing: Pharos engraving hero; snapshot revert hardening#9
Aayam Bansal (aayambansal) merged 3 commits into
mainfrom
landing-pharos-hero

Conversation

@aayambansal

@aayambansal Aayam Bansal (aayambansal) commented Jul 4, 2026

Copy link
Copy Markdown
Member

Landing (openscience.sh)

The Lighthouse of Alexandria engraving becomes the hero backdrop — the beam sweeps from the tower down to the small ship steering by its light at bottom-left.

  • Wordmark top-left over the dark sky; headline, lede, and CTAs bottom-right — both on quiet areas of the plate, so the beam and the ship stay fully in view.
  • Light uniform scrim + two corner shields for type legibility; the plate is already monochrome warm sepia, so no filter.
  • Replaces the constellation canvas.
  • Drops public/og.png and its og:image/twitter:image meta tags (twitter card falls back to summary).

Verified: bun run build clean; rendered at 1440×900 via vite preview.

Snapshot: revert must never delete on unverified state

The required Test check flaked on main ('unicode filenames modification and restore', ENOENT after revert — every sandbox file deleted). Root cause chain:

  1. track() swallowed a transient git add failure via .nothrow(); write-tree then snapshots an empty index, and revert() deletes every file as 'not in snapshot'. Fixed with a shared stageAll() that retries once and reports failure — track() returns no snapshot instead of a wrong one.
  2. revert() verified deletions with a per-file ls-tree <hash> -- <pathspec> whose behavior differs across platforms for unusual filenames. Replaced with one ls-tree -r --name-only listing per snapshot (quotepath=false, same mechanism patch() uses) checked in code — deterministic everywhere, fewer git calls, and fail-safe: if the listing errors, files are kept rather than deleted (a transient git error during revert could previously delete user files).

Verified: full backend/cli suite passes locally (818 tests); snapshot file 41/41; turbo typecheck clean.

The 'unicode filenames modification and restore' test failed CI on push
43b5e18 with ENOENT after revert: every file in the sandbox was deleted.
That happens when the 'git add' inside track() fails transiently and
.nothrow() swallows it — write-tree then snapshots an empty index, and
revert() against that tree treats every file as 'not in snapshot' and
unlinks it.

- stage via a shared stageAll() that retries once on failure and reports
  it; track() returns no snapshot instead of a wrong one when staging or
  write-tree fails
- revert() no longer deletes a file when the ls-tree verification itself
  errors; deletion now requires a successful ls-tree that confirms the
  file was absent from the snapshot
The Lighthouse of Alexandria plate becomes the hero backdrop — the beam
sweeps from the tower down to the small ship steering by its light at
bottom-left. The wordmark moves to the top-left over the dark sky and
the headline block to the bottom-right, so both sit on quiet areas of
the plate. A light uniform scrim plus two corner shields keep the type
crisp while the beam and the ship stay in view; the plate is monochrome
warm sepia already, so it ships unfiltered.

Replaces the constellation canvas. og.png and its meta tags go — the
twitter card drops to summary.
@vercel

vercel Bot commented Jul 4, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
openscience Ready Ready Preview, Comment Jul 4, 2026 6:19pm

Request Review

The per-file 'ls-tree <hash> -- <pathspec>' check behaved differently
across platforms for unusual filenames, so revert either kept files it
should delete or vice versa depending on OS. List the snapshot tree once
per patch with core.quotepath=false (the same mechanism patch() uses)
and check membership in code: deterministic on every platform, one git
call per snapshot instead of per file, and still fails safe — if the
listing errors, files are kept rather than deleted on an unverified
miss.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant